Link to this headingCounter Mode (CTR)
This is GCM mode but without the GHASH MAC.
Link to this headingAttacks
Link to this headingCTR Bit flipping
=
=
= b
=
#Unencrypted: b'comment="test";admin=false;username=test'
=
#Encrypted: b'y\x8f%\xa1Wo\xc3\x01\xec\xc6\xf1\t6?\xdfT\xcc\x99\xfaw\x84\x04\x85J\x0c\x10a\xfa!\xbf5!\x13\x04\x15\x08\xf9i8\x81'
### Remove the admin=false from ciphertext
= b * + b + b *
=
=
#Removed Tag Encrypted: b'y\x8f%\xa1Wo\xc3\x01\xec\xc6\xf1\t6?\xdf5\xa8\xf4\x93\x19\xb9b\xe4&\x7fua\xfa!\xbf5!\x13\x04\x15\x08\xf9i8\x81'
#Removed Tag unencrypted b'comment="test";\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00;username=test'
### Add the admin=true; to the ciphertext
= b * + b + b *
=
=
#Added Tag Encrypted: b'y\x8f%\xa1Wo\xc3\x01\xec\xc6\xf1\t6?\xdfT\xcc\x99\xfaw\x84\x16\x96S\x1aNa\xfa!\xbf5!\x13\x04\x15\x08\xf9i8\x81'
#Added Tag unencrypted b'comment="test";admin=true;;username=test'